package com.victor.entity.hotel;

import java.util.List;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 酒店图片组
 * 
 * @author zhangbin
 *
 */
@Entity
@Table(name = "hotel_photo_group")
@Data
@NoArgsConstructor
@AllArgsConstructor
public class HotelPhotoGroup {
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY) // 主键类型--自动递增生成
	@Column(name = "g_id", unique = true, nullable = false, length = 11)
	private Integer g_id;

	@Column(name = "g_name", length = 50)
	private String g_name;// 组名称

	@Column(name = "h_id", length = 50)
	private String h_id;// 酒店id

	@Transient
	private int number;// 组内图片数量

	@Transient
	private List<HotelPhoto> hotelPhotos;// 酒店图片

}
